<?php

namespace App\Http\Controllers\Admin;

use App\Models\BingRen;
use Illuminate\Http\Request;

use App\Http\Requests;
use App\Http\Controllers\Controller;

class DataController extends Controller
{
    public function index()
    {
        $from = date('Y-m-d H:i:s', mktime(0,0,0,date('m'),1,date('Y')));
        $to = date('Y-m-d H:i:s', mktime(23,59,59,date('m'),date('t'),date('Y')));
        $benyue = BingRen::where('created_at','>',$from)->where('created_at','<',$to)->count();

        return view('admin.data.index');
    }
}
